import http from '../../service/http'
// 用户信息
export function getUserInfoAPI(userId) {
  return http.get(`user/${userId}/getUserInfo/undefined`)
}
// 获赞数
export function getLikesNumAPI(userId) {
  return http.get(`user/${userId}/byLikesNum`)
}
// 关注数
export function getFollowersNumAPI(userId) {
  return http.get(`user/${userId}/FollowersNum`)
}
// 粉丝数
export function getFansNumAPI(userId) {
  return http.get(`user/${userId}/FansNum`)
}
// // 作品数量
export function getVideosNumAPI(userId) {
  return http.get(`user/${userId}/VideosNum`)
}
// 喜欢数量
export function getUserLikesAPI(userId) {
  return http.get(`user/${userId}/LikesNum`)
}
// 作品视频列表
export function getUserVideosAPI(userId, pageNum) {
  return http.get(`user/${userId}/Videos/page/${pageNum}`)
}
// 动态视频列表
export function getUserDynamicVideosAPI(userId, pageNum) {
  return http.get(`user/${userId}/Videos/page/${pageNum}`)
}
// 喜欢视频列表
export function getUserLikedVideosAPI(userId, pageNum) {
  return http.get(`user/${userId}/Likes/page/${pageNum}`)
}
// 修改用户信息
export function modifyUserInfoAPI(userId, userInfo) {
  return http.post(`user/${userId}/modifyUserInfo`, userInfo)
}

// 获取关注用户列表
export function getFollowersAPI(userId, pageNum) {
  return http.get(`user/${userId}/Followers/page/${pageNum}/${userId}`)
}

// 获取粉丝用户列表
export function getFansAPI(userId, pageNum) {
  return http.get(`user/${userId}/Fans/page/${pageNum}/${userId}`)
}
// 请求别人主页
export function getUserProfileAPI(currentUserId, userId) {
  return http.get(`user/${currentUserId}/getUserInfo/${userId}`)
}
// 获取联系人列表
export function getContactAPI(userId) {
  return http.get(`user/${userId}/getContact`)
}
// 上传头像
export function uploadAvatarAPI(userId, formData) {
  return http.post(`user/${userId}/uploadAvatar`, formData)
}
